<form action="/admin/settings" method="post">
	
	<? foreach($settings as $name=>$value): ?>
	<label>
		<?= file2class($name, true) ?>:<br />
		<input type="text" name="settings[<?= $name ?>]" value="<?= htmlentities($value, ENT_QUOTES, "utf-8") ?>" />
	</label>
	<? endforeach; ?>
	
	<input type="submit" value="Sačuvaj" />
</form>
<? if(isset($saved)): ?>
	<br clear="all" />
	<div class="message <?= $saved ? "ok" : "error" ?>"><?= $saved ? "Podešavanja su uspešno sačuvana." : "Čuvanje neuspelo!" ?></div>
<? endif; ?>

<script type="text/javascript">
setTimeout(function(){
	$(".message").fadeOut();
}, 2500);
</script>